/*
 * An XML document type.
 * Localname: src
 * Namespace: http://sei.buaa.edu/mdt/tli
 * Java type: edu.buaa.sei.mdt.tli.SrcDocument
 *
 * Automatically generated - do not modify.
 */
package edu.buaa.sei.mdt.tli.impl;
/**
 * A document containing one src(@http://sei.buaa.edu/mdt/tli) element.
 *
 * This is a complex type.
 */
public class SrcDocumentImpl extends org.apache.xmlbeans.impl.values.XmlComplexContentImpl implements edu.buaa.sei.mdt.tli.SrcDocument
{
    private static final long serialVersionUID = 1L;
    
    public SrcDocumentImpl(org.apache.xmlbeans.SchemaType sType)
    {
        super(sType);
    }
    
    private static final javax.xml.namespace.QName SRC$0 = 
        new javax.xml.namespace.QName("http://sei.buaa.edu/mdt/tli", "src");
    
    
    /**
     * Gets the "src" element
     */
    public edu.buaa.sei.mdt.tli.SrcDocument.Src getSrc()
    {
        synchronized (monitor())
        {
            check_orphaned();
            edu.buaa.sei.mdt.tli.SrcDocument.Src target = null;
            target = (edu.buaa.sei.mdt.tli.SrcDocument.Src)get_store().find_element_user(SRC$0, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * Sets the "src" element
     */
    public void setSrc(edu.buaa.sei.mdt.tli.SrcDocument.Src src)
    {
        generatedSetterHelperImpl(src, SRC$0, 0, org.apache.xmlbeans.impl.values.XmlObjectBase.KIND_SETTERHELPER_SINGLETON);
    }
    
    /**
     * Appends and returns a new empty "src" element
     */
    public edu.buaa.sei.mdt.tli.SrcDocument.Src addNewSrc()
    {
        synchronized (monitor())
        {
            check_orphaned();
            edu.buaa.sei.mdt.tli.SrcDocument.Src target = null;
            target = (edu.buaa.sei.mdt.tli.SrcDocument.Src)get_store().add_element_user(SRC$0);
            return target;
        }
    }
    /**
     * An XML src(@http://sei.buaa.edu/mdt/tli).
     *
     * This is an atomic type that is a restriction of edu.buaa.sei.mdt.tli.SrcDocument$Src.
     */
    public static class SrcImpl extends org.apache.xmlbeans.impl.values.JavaStringHolderEx implements edu.buaa.sei.mdt.tli.SrcDocument.Src
    {
        private static final long serialVersionUID = 1L;
        
        public SrcImpl(org.apache.xmlbeans.SchemaType sType)
        {
            super(sType, true);
        }
        
        protected SrcImpl(org.apache.xmlbeans.SchemaType sType, boolean b)
        {
            super(sType, b);
        }
        
        private static final javax.xml.namespace.QName TYPE$0 = 
            new javax.xml.namespace.QName("", "type");
        
        
        /**
         * Gets the "type" attribute
         */
        public java.lang.String getType()
        {
            synchronized (monitor())
            {
                check_orphaned();
                org.apache.xmlbeans.SimpleValue target = null;
                target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(TYPE$0);
                if (target == null)
                {
                    return null;
                }
                return target.getStringValue();
            }
        }
        
        /**
         * Gets (as xml) the "type" attribute
         */
        public edu.buaa.sei.mdt.tli.SrcDocument.Src.Type xgetType()
        {
            synchronized (monitor())
            {
                check_orphaned();
                edu.buaa.sei.mdt.tli.SrcDocument.Src.Type target = null;
                target = (edu.buaa.sei.mdt.tli.SrcDocument.Src.Type)get_store().find_attribute_user(TYPE$0);
                return target;
            }
        }
        
        /**
         * Sets the "type" attribute
         */
        public void setType(java.lang.String type)
        {
            synchronized (monitor())
            {
                check_orphaned();
                org.apache.xmlbeans.SimpleValue target = null;
                target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(TYPE$0);
                if (target == null)
                {
                    target = (org.apache.xmlbeans.SimpleValue)get_store().add_attribute_user(TYPE$0);
                }
                target.setStringValue(type);
            }
        }
        
        /**
         * Sets (as xml) the "type" attribute
         */
        public void xsetType(edu.buaa.sei.mdt.tli.SrcDocument.Src.Type type)
        {
            synchronized (monitor())
            {
                check_orphaned();
                edu.buaa.sei.mdt.tli.SrcDocument.Src.Type target = null;
                target = (edu.buaa.sei.mdt.tli.SrcDocument.Src.Type)get_store().find_attribute_user(TYPE$0);
                if (target == null)
                {
                    target = (edu.buaa.sei.mdt.tli.SrcDocument.Src.Type)get_store().add_attribute_user(TYPE$0);
                }
                target.set(type);
            }
        }
        /**
         * An XML type(@).
         *
         * This is an atomic type that is a restriction of edu.buaa.sei.mdt.tli.SrcDocument$Src$Type.
         */
        public static class TypeImpl extends org.apache.xmlbeans.impl.values.JavaStringHolderEx implements edu.buaa.sei.mdt.tli.SrcDocument.Src.Type
        {
            private static final long serialVersionUID = 1L;
            
            public TypeImpl(org.apache.xmlbeans.SchemaType sType)
            {
                super(sType, false);
            }
            
            protected TypeImpl(org.apache.xmlbeans.SchemaType sType, boolean b)
            {
                super(sType, b);
            }
        }
    }
}
